package com.project.bean;

/**
 * 评论实体类
 */

public class SpeakBean {
    /**评论id*/
    private int id;
    /** 评论人*/
    private UserBean userBean;
    /**评论内容*/
    private String content;
    /** 商品对象*/
    private ProductBean productBean;

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public UserBean getUserBean() {
        return userBean;
    }
    public void setUserBean(UserBean userBean) {
        this.userBean = userBean;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public ProductBean getProductBean() {
        return productBean;
    }

    public void setProductBean(ProductBean productBean) {
        this.productBean = productBean;
    }

    @Override
    public String toString() {
        return "CommentBean{" +
                "id=" + id +
                ", userBean=" + userBean +
                ", content='" + content + '\'' +
                ", productBean=" + productBean +
                '}';
    }

    public SpeakBean() {

    }

    public SpeakBean(int userId, String content, int productId) {
        this.userBean = new UserBean();
        userBean.setId(userId);
        this.content = content;
        this.productBean = new ProductBean();
        productBean.setId(productId);
    }
}
